<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@page import="com.zjf.entity.Article"%>
<%@page import="java.text.SimpleDateFormat"%>
<%@page import="java.net.URLDecoder"%>
<%@page import="com.zjf.entity.Review"%>
<%@page import="com.zjf.dao.impl.ReviewDaoImpl"%>
<%!
	List<Review> reviews = new ArrayList<Review>();
	
%>
<%
	try{String rid = request.getParameter("rid");
	if(rid==null ||"".equals("rid")){
		response.sendRedirect("admin/manage.jsp");
		return;
	}else{
		int id = Integer.parseInt(rid);
		reviews = new ReviewDaoImpl().queryReviewsByA_id(id);
	}
	}catch(Exception e){
			response.sendRedirect("error.jsp?id=100");
	}
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>replys</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<link rel="stylesheet" type="text/css" href="style/style.css" />

  </head>
  <body>
    <center>
    <div id ="wrap">
		
	
			<jsp:include page="head.jsp"></jsp:include>
			
			<div id="center_pad1">
				<%for(Review a:reviews){ %>
					<%=a.getAuthor()%>:<%=a.getContent() %> at <%=a.getPubDate() %></br></br>
				<%} %>
			</div>
			
			<jsp:include page="foot.jsp"></jsp:include>
  </div>
  </body>
</html>
